<template>
	<u-collapse v-if="list.length">
		<u-collapse-item v-for="(v, k) in list" :key="k">
			<view slot="title" class="item-hd" @click.stop="toPath(v)">
				<o-row justify="between" align="center" class="o-row">
					<o-col span="20" class="o-col title">
						<text class="key">商机名称：</text>
						<text class="val">{{ v.businessName }}</text>
					</o-col>
					<o-col span="4" class="o-col text-right">
						<u-tag plain size="mini" :type="$enum.status[v.checkStatus].type" :text="$enum.status[v.checkStatus].text"></u-tag>
					</o-col>
				</o-row>
				<o-row justify="between" class="o-row">
					<o-col span="12" class="o-col">金额：¥{{ v.money || '0.00' }}</o-col>
					<o-col span="12" class="o-col text-right">预计成交：{{ v.dealDate || '--' }}</o-col>
				</o-row>
			</view>
			<view class="item-bd">
				<o-row justify="between" class="o-row">
					<o-col span="12" class="o-col">创建人：{{ v.createUserName }}</o-col>
					<o-col span="12" class="o-col text-right">负责人：{{ v.ownerUserName }}</o-col>
				</o-row>
				<o-row class="o-row">客户名称：{{ v.customerName }}</o-row>
				<o-row class="o-row">更新时间：{{ v.updateTime }}</o-row>
				<o-row class="o-row">创建时间：{{ v.createTime }}</o-row>
			</view>
		</u-collapse-item>
	</u-collapse>
</template>

<script>
import oRow from '@/components/oveui-layout/o-row/o-row.vue';
import oCol from '@/components/oveui-layout/o-col/o-col.vue';
export default {
	name: 'customer',
	components: { oRow, oCol },
	props: {
		list: {
			type: Array,
			default() {
				return [];
			},
		},
	},
	data() {
		return {};
	},
	mounted() {},
	methods: {
		toPath(v) {
			this.$emit('toPath', v);
		},
	},
};
</script>

<style lang="scss" scoped>
</style>